package com.zzyl.nursing.service;

import java.util.List;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.zzyl.common.core.domain.R;
import com.zzyl.nursing.domain.Reservation;
import com.baomidou.mybatisplus.extension.service.IService;
import com.zzyl.nursing.domain.Reservation;
import com.zzyl.nursing.dto.ReservationDto;
import com.zzyl.common.core.domain.AjaxResult;
import com.zzyl.nursing.domain.Reservation;
import com.baomidou.mybatisplus.extension.service.IService;
import com.zzyl.nursing.dto.ReservationListDto;

/**
 * 预约信息Service接口
 * 
 * @author ruoyi
 * @date 2025-03-02
 */


public interface IReservationService extends IService<Reservation>
{
    /**
     * 查询预约信息
     * 
     * @param id 预约信息主键
     * @return 预约信息
     */
    public Reservation selectReservationById(Long id);

    /**
     * 查询预约信息列表
     * 
     * @param reservation 预约信息
     * @return 预约信息集合
     */
    public List<Reservation> selectReservationList(Reservation reservation);

    /**
     * 新增预约信息
     * 
     * @param reservation 预约信息
     * @return 结果
     */
    public int insertReservation(ReservationDto reservation);


    long reservationListRm();


    List<ReservationListDto> reservationList(Long time);

    Page reservationPage(Integer pageSize, Integer pageNum, Integer status);

    void autoCancel();
    Long cancelledCount();

    /**
     *更新合同状态
     */
    void updateReservationStatus();
    /**
     *取消预约
     */
    int cancel(Long id);
}
